package com.laizhenghua.hotel.service.impl;

import com.laizhenghua.hotel.utils.PageUtils;
import com.laizhenghua.hotel.utils.Query;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.stereotype.Service;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import com.laizhenghua.hotel.dao.HouseDao;
import com.laizhenghua.hotel.entity.HouseEntity;
import com.laizhenghua.hotel.service.HouseService;


@Service("houseService")
public class HouseServiceImpl extends ServiceImpl<HouseDao, HouseEntity> implements HouseService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        IPage<HouseEntity> page = this.page(
                new Query<HouseEntity>().getPage(params),
                new QueryWrapper<HouseEntity>()
        );

        return new PageUtils(page);
    }

}